Optimal. Leaf size=114 \[ \frac {(A+B) \cos (e+f x) (a+a \sin (e+f x))^m (c-c \sin (e+f x))^{-2-m}}{f (3+2 m)}+\frac {(A-2 B (1+m)) \cos (e+f x) (a+a \sin (e+f x))^m (c-c \sin (e+f x))^{-1-m}}{c f (1+2 m) (3+2 m)} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.15, antiderivative size = 114, normalized size of antiderivative = 1.00, number of steps
used = 2, number of rules used = 2, integrand size = 40, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.050, Rules used = {3051, 2821}
\begin {gather*} \frac {(A+B) \cos (e+f x) (a \sin (e+f x)+a)^m (c-c \sin (e+f x))^{-m-2}}{f (2 m+3)}+\frac {(A-2 B (m+1)) \cos (e+f x) (a \sin (e+f x)+a)^m (c-c \sin (e+f x))^{-m-1}}{c f (2 m+1) (2 m+3)} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 2821
Rule 3051
Rubi steps
\begin {align*} \int (a+a \sin (e+f x))^m (A+B \sin (e+f x)) (c-c \sin (e+f x))^{-2-m} \, dx &=\frac {(A+B) \cos (e+f x) (a+a \sin (e+f x))^m (c-c \sin (e+f x))^{-2-m}}{f (3+2 m)}+\frac {(A-2 B (1+m)) \int (a+a \sin (e+f x))^m (c-c \sin (e+f x))^{-1-m} \, dx}{c (3+2 m)}\\ &=\frac {(A+B) \cos (e+f x) (a+a \sin (e+f x))^m (c-c \sin (e+f x))^{-2-m}}{f (3+2 m)}+\frac {(A-2 B (1+m)) \cos (e+f x) (a+a \sin (e+f x))^m (c-c \sin (e+f x))^{-1-m}}{c f (1+2 m) (3+2 m)}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 11.73, size = 211, normalized size = 1.85 \begin {gather*} -\frac {2^{-7-m} \cos \left (\frac {1}{2} \left (-e+\frac {\pi }{2}-f x\right )\right ) \csc ^9\left (\frac {1}{8} \left (-e+\frac {\pi }{2}-f x\right )\right ) \sec ^3\left (\frac {1}{8} \left (-e+\frac {\pi }{2}-f x\right )\right ) \sin ^{-2 m}\left (\frac {1}{2} \left (-e+\frac {\pi }{2}-f x\right )\right ) \left (\cos \left (\frac {1}{2} (e+f x)\right )-\sin \left (\frac {1}{2} (e+f x)\right )\right )^{-2 (-2-m)} (a+a \sin (e+f x))^m (c-c \sin (e+f x))^{-2-m} (B-2 A (1+m)+(A-2 B (1+m)) \sin (e+f x))}{f \left (3+8 m+4 m^2\right ) \left (-1+\cot ^2\left (\frac {1}{8} \left (-e+\frac {\pi }{2}-f x\right )\right )\right )^3} \end {gather*}
Warning: Unable to verify antiderivative.
[In]
[Out]
________________________________________________________________________________________
Maple [F]
time = 0.59, size = 0, normalized size = 0.00 \[\int \left (a +a \sin \left (f x +e \right )\right )^{m} \left (A +B \sin \left (f x +e \right )\right ) \left (c -c \sin \left (f x +e \right )\right )^{-2-m}\, dx\]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Failed to integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A]
time = 0.41, size = 94, normalized size = 0.82 \begin {gather*} \frac {{\left ({\left (2 \, B m - A + 2 \, B\right )} \cos \left (f x + e\right ) \sin \left (f x + e\right ) + {\left (2 \, A m + 2 \, A - B\right )} \cos \left (f x + e\right )\right )} {\left (a \sin \left (f x + e\right ) + a\right )}^{m} {\left (-c \sin \left (f x + e\right ) + c\right )}^{-m - 2}}{4 \, f m^{2} + 8 \, f m + 3 \, f} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F(-2)]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Exception raised: SystemError} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [B]
time = 14.16, size = 134, normalized size = 1.18 \begin {gather*} -\frac {{\left (a\,\left (\sin \left (e+f\,x\right )+1\right )\right )}^m\,\left (4\,A\,\cos \left (e+f\,x\right )-2\,B\,\cos \left (e+f\,x\right )-A\,\sin \left (2\,e+2\,f\,x\right )+2\,B\,\sin \left (2\,e+2\,f\,x\right )+4\,A\,m\,\cos \left (e+f\,x\right )+2\,B\,m\,\sin \left (2\,e+2\,f\,x\right )\right )}{c^2\,f\,{\left (-c\,\left (\sin \left (e+f\,x\right )-1\right )\right )}^m\,\left (4\,m^2+8\,m+3\right )\,\left (4\,\sin \left (e+f\,x\right )+\cos \left (2\,e+2\,f\,x\right )-3\right )} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________